package Test01;

public class test3 {

    public static void main(String[] args) {

        int arr[] = {48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 97, 98, 99, 100, 101, 102}; //定义一个数组存放棋盘行列的ascll码值
        for (int i = 0; i < arr.length; i++) {
            if(i==0){   //第一行首先输出空格，再输出相应的字符
                System.out.print("   ");
                for (int j = 0; j < arr.length; j++) {
                    System.out.print((char) arr[j]);//ascll转为字符输出
                    System.out.print("  ");//每输出一个字符输出两个空格

                }
                System.out.print('\n');//换行
            }
            else{
                System.out.print((char) arr[i]);
                System.out.print("  ");
                for (int j = 0; j < arr.length; j++) {
                    System.out.print('+');
                    System.out.print("  ");
                }
                System.out.print('\n');

            }

        }
    }
}
